<?php

namespace Library\Entities;

class Inscription extends \Library\Entity {

    protected $email, $password, $name;

    const MAIL_INVALIDE = 1;
    const MDP_INVALIDE = 2;
    const NAME_INVALIDE = 3;

    public function isValid() {
        return !(empty($this->email) || empty($this->password));
    }

    // SETTERS //
    public function setEmail($email) {
            $this->email = $email;
    }

    public function setName($name) {
            $this->name = $name;
    }

    public function setPassword($password) {
            $this->password = $password;
    }

    // GETTERS //
    public function email() {
        return $this->email;
    }

    public function password() {
        return $this->password;
    }

    public function name() {
        return $this->name;
    }
}

?>
